package com.haoqizhe.kernel.core.entity;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serializable;
import java.util.List;

/**
 * 树
 * @author haoqizhe.li
 * @date 2018/6/26
 **/
@Data
@NoArgsConstructor
@AllArgsConstructor
@ApiModel(value = "树根实体")
public class TreeEntity implements Serializable{

    @ApiModelProperty(value = "树节点等级")
    private String level;
    @ApiModelProperty(value = "节点id")
    private String id;
    @ApiModelProperty(value = "父节点id")
    private String pid;
    @ApiModelProperty(value = "节点名称")
    private String text;
    @ApiModelProperty(value = "是否选中")
    private boolean checked = false;
    @ApiModelProperty(value = "状态,为true时可选，为false时不可选")
    private boolean state = false;
    @ApiModelProperty(value = "顺序号")
    private Integer seqNo;

    @ApiModelProperty(value = "子节点")
    private List<TreeEntity> children;
}
